<!DOCTYPE html>
<html lang="en">

<head>
    <title></title>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <block name="style">
        <link rel="stylesheet" href="__MYCSS__/main.min.css">
        <link rel="stylesheet" type="text/css" href="__STATIC__/uploadify/uploadify.css" />
        <style>
            ._citys {
                width: 450px;
                display: inline-block;
                border: 2px solid #eee;
                padding: 5px;
                position: relative;
                background: #fff;
            }

            ._citys span {
                color: #18bc9c;
                height: 15px;
                width: 15px;
                line-height: 15px;
                text-align: center;
                border-radius: 3px;
                position: absolute;
                right: 10px;
                top: 10px;
                border: 1px solid #18bc9c;
                cursor: pointer;
            }

            ._citys0 {
                width: 100%;
                height: 34px;
                display: inline-block;
                border-bottom: 2px solid #18bc9c;
                padding: 0;
                margin: 0;
            }

            ._citys0 li {
                display: inline-block;
                line-height: 34px;
                font-size: 15px;
                color: #888;
                width: 80px;
                text-align: center;
                cursor: pointer;
            }

            .citySel {
                background-color: #18bc9c;
                color: #fff !important;
            }

            ._citys1 {
                width: 100%;
                display: inline-block;
                padding: 10px 0;
            }

            ._citys1 a {
                width: 83px;
                height: 35px;
                display: inline-block;
                background-color: #f5f5f5;
                color: #666;
                margin-left: 6px;
                margin-top: 3px;
                line-height: 35px;
                text-align: center;
                cursor: pointer;
                font-size: 13px;
                overflow: hidden;
            }

            ._citys1 a:hover {
                color: #fff;
                background-color: #18bc9c;
            }

            .AreaS {
                background-color: #18bc9c !important;
                color: #fff !important;
            }
        </style>
    </block>
</head>
<extend name="Public/base" />
<block name="body">

    <body>

        <ol class="breadcrumb">
            <li><a href="#">FTTH业务管理</a></li>
            <li class="active">FTTH业务管理</li>
        </ol>
        <div style="margin-bottom: 4px">
            <a class="btn btn-primary" role="button" data-toggle="collapse" href="#collapseExample" aria-expanded="true" aria-controls="collapseExample">查询</a>
            <button type="button" class="btn btn-default" data-toggle="modal" data-target="#addModal">添加</button>
            <div id="uploader" class="wu-example btn btn-primary">
                <div class="btns">
                    <div id="picker">Excel导入</div>
                </div>
            </div>
            <a class="btn btn-primary" href="{:U('csv_export',array('txt_name'=>$txt_name))}">csv导出</a>
            <div id="thelist" class="uploader-list">
            </div>
        </div>

        <div class="collapse" id="collapseExample">
            <div class="well">
                <form method="GET" action="{:U('lst')}">
                    <div class="row">
                        <div class="col-lg-1">
                            <div class="form-group">
                                <label for="year">所属年份：</label>
                                <select class="form-control father_select year_select" name="year">
                                <option value="">--请选择--</option>
                            </select>
                            </div>
                        </div>
                        <div class="col-lg-1">
                            <div class="form-group">
                                <label for="month">所属月份：</label>
                                <select class="form-control son_select month_select" name="month" disabled="disabled">
                                <option value="">--请选择--</option>
                            </select>
                            </div>
                        </div>
                        <div class="col-lg-2 col-sm-6">
                            <div class="form-group">
                                <label for="exampleInputName2">开通地点</label>
                                <select class="form-control" name="ktdd">
                                    <option value="">--请选择--</option>
                                    <volist name="ktdd_arr" id="ktdd">
                                        <option value="{$ktdd}">{$ktdd}</option>
                                    </volist>
                                 </select>
                            </div>
                        </div>
                        <div class="col-lg-2 col-sm-6">
                            <div class="form-group">
                                <label for="exampleInputName2">地区：</label>
                                <select class="form-control" name="dq">
                                    <option value="">--请选择--</option>
                                    <volist name="dq_arr" id="dq">
                                        <option value="{$dq}">{$dq}</option>
                                    </volist>
                                 </select>
                            </div>
                        </div>
                        <div class="col-lg-2 col-sm-6">
                            <div class="form-group">
                                <label for="exampleInputName2">业务账号：</label>
                                <input type="text" class="form-control" name="ywzh" value="">
                            </div>
                        </div>
                        <div class="col-lg-2 col-sm-6">
                            <div class="form-group">
                                <label for="exampleInputName2">开通时间：</label>
                                <input type="text" class="form-control form_date" name="ktrq" value="" data-date-format="yyyy-mm-dd" readonly>
                            </div>
                        </div>
                        <div class="col-lg-2 col-sm-6">
                            <div class="form-group">
                                <label for="exampleInputName2">停用日期：</label>
                                <input type="text" class="form-control form_date" name="jsrq" value="" data-date-format="yyyy-mm-dd" readonly>
                            </div>
                        </div>
                        <div class="col-lg-2 col-sm-3" style="margin-top: 25px;">
                            <button type="submit" class="btn btn-success">查询</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>
        <div class="panel panel-default">
            <div class="panel-heading">客户资源表</div>
            <div class="surface_table">
                <div class="table-head">
                    <table class="table table-bordered">
                        <thead>
                            <tr class="table-h">
                                <th>所属时间</th>
                                <th>地区</th>
                                <th>开通地点</th>
                                <th>业务账号</th>
                                <th>资源属性</th>
                                <th>条数</th>
                                <th>数量</th>
                                <th>状态</th>
                                <th>是否开票</th>
                                <th>业务备注</th>
                                <th>开通日期</th>
                                <th>计费日期</th>
                                <th>终止日期</th>
                                <th>缴费方式</th>
                                <th>单价</th>
                                <th>应缴未缴金额费</th>
                                <th>缴费金额</th>
                                <th>安装费用</th>
                                <th>付款日期</th>
                                <th>借款日期</th>
                                <th>借款备注</th>
                                <th>冲借款日期</th>
                                <th>本月实际费用小计</th>
                                <th>余额（预付）结余</th>
                                <th>操作</th>
                            </tr>
                        </thead>
                    </table>
                </div>
                <div class="table-body">
                    <table class="table table-hover table-bordered">
                        <tbody>
                            <volist name="lsts" id="list">
                                <tr>
                                    <td>{$list.sssj}</td>
                                    <td>{$list.dq}</td>
                                    <td>{$list.ktdd}</td>
                                    <td>{$list.ywzh}</td>
                                    <td>{$list.sx}</td>
                                    <td>{$list.ts}</td>
                                    <td>{$list.sl}</td>
                                    <td>{$list.zt}</td>
                                    <td>{$list.kp}</td>
                                    <td>{$list.ywbz}</td>
                                    <td>{$list.ktrq}</td>
                                    <td>{$list.jfrq}</td>
                                    <td>{$list.jsrq}</td>
                                    <td>{$list.jffs}</td>
                                    <td>{$list.dj}</td>
                                    <td class="count_yjwj">{$list.yjwj}</td>
                                    <td class="count_jfje">{$list.jfje}</td>
                                    <td class="count_azfy">{$list.azfy}</td>
                                    <td>{$list.fkrq}</td>
                                    <td>{$list.jkrq}</td>
                                    <td>{$list.fkbz}</td>
                                    <td>{$list.cjqrq}</td>
                                    <td class="count_xj" style="min-width:140px">{$list.xj}</td>
                                    <td class="count_jy" style="min-width:140px">{$list.jy}</td>
                                    <td>
                                        <button type="button" data-id="{$list.id}" class="btn btn-warning update_btn" data-toggle="modal" data-target="#updateModal">修改</button>
                                        <a class="btn btn-danger delete_btn" href="{:U('del',array('id'=>$list['id']))}" role="button">删除</a>
                                    </td>
                                </tr>
                            </volist>
                            <tr>
                                <td colspan="14" style="text-align: center">总计</td>
                                <td id="count_yjwj" class="count"></td>
                                <td id="count_jfje" class="count"></td>
                                <td id="count_azfy" class="count"></td>
                                <td colspan="5"></td>
                                <td id="count_xj" class="count"></td>
                                <td id="count_jy" class="count"></td>
                                <td></td>
                            </tr>
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
        <!--添加面板-->
        <div class="modal fade bs-example-modal-lg" id="addModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
            <div class="modal-dialog modal-lg" role="document">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                        <h4 class="modal-title" id="myModalLabel">增加FTTH表单</h4>
                    </div>
                    <div class="modal-body">
                        <form class="public_form khzyForm" action="{:U('add')}" method="post">
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addsssj">所属时间</label>
                                        <input type="text" class="form-control form_date" id="addsssj" name="sssj" value="" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addcity">地区</label>
                                        <input type="text" class="form-control" value="" id="addcity" name="dq">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addktdd">开通地点</label>
                                        <input type="text" class="form-control" id="addktdd" name="ktdd">
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addywzh">业务账号</label>
                                        <input type="text" class="form-control" id="addywzh" name="ywzh">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addsx">资源属性</label>
                                        <input type="text" class="form-control" value="" id="addsx" name="sx">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addts">条数</label>
                                        <input type="text" class="form-control" value="" id="addts" name="ts">
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addsl">数量</label>
                                        <input type="text" class="form-control" id="addsl" name="sl">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="zt">状态：</label>
                                        <div>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="zt" id="addzt" value="在用" checked> 在用
                                            </label>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="zt" id="addzt" value="停用"> 停用
                                            </label>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="zt" id="addzt" value="终止"> 终止
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="col-lg-4">
                                    <div class="form-group">
                                        <label for="kp">是否开票：</label>
                                        <div>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="kp" id="addkp" value="是" checked> 是
                                            </label>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="kp" id="addkp" value="否"> 否
                                            </label>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addktrq">开通日期</label>
                                        <input type="text" class="form-control form_date" id="addktrq" name="ktrq" value="" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addjfrq">计费日期</label>
                                        <input type="text" class="form-control form_date" id="addjfrq" name="jfrq" value="" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addjsrq">终止日期</label>
                                        <input type="text" class="form-control form_date" value="" id="addjsrq" name="jsrq" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="exampleInputName2">缴费方式</label>
                                        <select class="form-control" name="jffs">
                                            <option value="按月">按月</option>
                                            <option value="按季度">按季度</option>
                                            <option value="按年">按年</option>
                                        </select>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="dj">单价:</label>
                                        <input type="text" class="form-control" id="adddj" name="dj">
                                    </div>
                                </div>
                                <div class="col-lg-4">
                                    <div class="form-group">
                                        <label for="addyjwj">应缴未缴金额</label>
                                        <input type="text" class="form-control" id="addyjwj" name="yjwj">
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addjfje">缴费金额</label>
                                        <input type="text" class="form-control" id="addjfje" name="jfje">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addazfy">安装费用</label>
                                        <input type="text" class="form-control" id="addazfy" name="azfy">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addfkrq">付款日期</label>
                                        <input type="text" class="form-control form_date" id="addfkrq form_date" data-date-format="yyyy-mm-dd" name="fkrq" readonly>
                                    </div>
                                </div>


                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addfkbz">付款备注</label>
                                        <input type="text" class="form-control" id="addfkbz" name="fkbz">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addjkrq">借款日期</label>
                                        <input type="text" class="form-control form_date" id="addjkrq form_date" data-date-format="yyyy-mm-dd" name="jkrq" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addcjqrq">冲借款日期</label>
                                        <input type="text" class="form-control form_date" id="addcjqrq" name="cjqrq" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addjy">余额（预付）结余</label>
                                        <input type="text" class="form-control" id="addjy" name="jy">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="addywbz">业务备注</label>
                                        <input type="text" class="form-control" id="addywbz" name="ywbz">
                                    </div>
                                </div>
                            </div>
                            <div class="modal-footer">
                                <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                                <button type="submit" class="btn btn-primary">保存表单</button>
                            </div>
                        </form>
                    </div>


                </div>
            </div>
        </div>
        <!--修改面板-->
        <div class="modal fade bs-example-modal-lg" id="updateModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
            <div class="modal-dialog modal-lg" role="document">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                        <h4 class="modal-title" id="myModalLabel">修改FTTH表单</h4>
                    </div>
                    <div class="modal-body">
                        <form class="public_form update_form" action="{:U('edit')}" method="post">
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatesssj">所属时间</label>
                                        <input type="text" class="form-control form_date" id="updatesssj" name="sssj" value="" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatecity">地区</label>
                                        <input type="text" class="form-control" value="" id="updatecity" name="dq">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatektdd">开通地点</label>
                                        <input type="text" class="form-control" id="updatektdd" name="ktdd">
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updateywzh">业务账号</label>
                                        <input type="text" class="form-control" id="updateywzh" name="ywzh">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatesx">资源属性</label>
                                        <input type="text" class="form-control" value="" id="updatesx" name="sx">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatets">条数</label>
                                        <input type="text" class="form-control" value="" id="updatets" name="ts">
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatesl">数量</label>
                                        <input type="text" class="form-control" id="updatesl" name="sl">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatezt">状态：</label>
                                        <div>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="zt" id="updatezt" value="在用" checked> 在用
                                            </label>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="zt" id="updatezt" value="停用"> 停用
                                            </label>
                                            <label class="checkbox-inline">
                                                <input type="radio" name="zt" id="updatezt" value="终止"> 终止
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="col-lg-4">
                                    <div class="form-group">
                                        <label for="kp">是否开票：</label>
                                        <div>
                                            <label class="checkbox-inline">
                                            <input type="radio" name="kp" id="updatekp" value="是" checked> 是
                                        </label>
                                            <label class="checkbox-inline">
                                            <input type="radio" name="kp" id="updatekp" value="否"> 否
                                        </label>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatektrq">开通日期</label>
                                        <input type="text" class="form-control form_date" id="updatektrq" name="ktrq" value="" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatejfrq">计费日期</label>
                                        <input type="text" class="form-control form_date" id="updatejfrq" name="jfrq" value="" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatejsrq">终止日期</label>
                                        <input type="text" class="form-control form_date" value="" id="updatejsrq" name="jsrq" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="exampleInputName2">缴费方式</label>
                                        <select class="form-control" name="jffs">
                                            <option value="按月">按月</option>
                                            <option value="按季度">按季度</option>
                                            <option value="按年">按年</option>
                                        </select>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="dj">单价:</label>
                                        <input type="text" class="form-control" id="updatedj" name="dj">
                                    </div>
                                </div>
                                <div class="col-lg-4">
                                    <div class="form-group">
                                        <label for="updateyjwj">应缴未缴金额</label>
                                        <input type="text" class="form-control" id="updateyjwj" name="yjwj">
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatejfje">缴费金额</label>
                                        <input type="text" class="form-control" id="updatejfje" name="jfje">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updateazfy">安装费用</label>
                                        <input type="text" class="form-control" id="updateazfy" name="azfy">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatefkrq">付款日期</label>
                                        <input type="text" class="form-control form_date" id="updatefkrq form_date" data-date-format="yyyy-mm-dd" name="fkrq" readonly>
                                    </div>
                                </div>


                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatefkbz">付款备注</label>
                                        <input type="text" class="form-control" id="updatefkbz" name="fkbz">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatejkrq">借款日期</label>
                                        <input type="text" class="form-control form_date" id="updatejkrq form_date" data-date-format="yyyy-mm-dd" name="jkrq" readonly>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatecjqrq">冲借款日期</label>
                                        <input type="text" class="form-control form_date" id="updatecjqrq" name="cjqrq" data-date-format="yyyy-mm-dd" readonly>
                                    </div>
                                </div>

                            </div>
                            <div class="row">
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updatejy">余额（预付）结余</label>
                                        <input type="text" class="form-control" id="updatejy" name="jy">
                                    </div>
                                </div>
                                <div class="col-lg-4 col-sm-4">
                                    <div class="form-group">
                                        <label for="updateywbz">业务备注</label>
                                        <input type="text" class="form-control" id="updateywbz" name="ywbz">
                                    </div>
                                </div>
                                <input type="hidden" class="form-control" id="updateid" name="id">
                            </div>
                            <div class="modal-footer">
                                <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                                <button type="submit" class="btn btn-primary">保存表单</button>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
            <script src="__MYJS__/main.min.js"></script>
            <script src="__MYJS__/table.js"></script>
            <script src="__MYJS__/main.js"></script>
            <script src="__MYJS__/validator.js"></script>
            <script type="text/javascript" src="__MYJS__/Popt.js"></script>
            <script type="text/javascript" src="__MYJS__/cityJson.js"></script>
            <script type="text/javascript" src="__MYJS__/citySet.js"></script>
            <script type="text/javascript" src="__MYJS__/upload.js"></script>
            <script>
                $(function () {
                    // 修改按钮事件
                    $("table").on("click", ".update_btn", function (e) {
                        e.stopPropagation();
                        var id = $(this).attr("data-id");
                        $.ajax({
                            url: "{:U('edit')}",
                            type: 'GET', //GET
                            data: {
                                id: id
                            },
                            success: function (data) {
                                $(".update_form .form-control").each(function (index, val) {
                                    var self = this;
                                    for (x in data) {
                                        if ($(self).attr("name") == x) {
                                            if (x == "kp" || x == "zt" && $(self).attr("name") == x) {
                                                $(":radio[name='" + x + "'][value='" +
                                                    data[x] +
                                                    "']").prop("checked", "checked");
                                            } else {
                                                $(self).val(data[x]);
                                            }
                                        }
                                    }
                                });
                                // 重新更新日期选择器
                                $(".update_form .form_date").each(function (index, val) {
                                    if ($(this).val() != "") {
                                        $(this).val(moment($(this).val(),
                                            "YYYYMMDD").format(
                                            "YYYY-MM-DD"))
                                    }
                                })
                                $(".update_form .form_date").datetimepicker('update');
                            }
                        })
                        $("#update_id").val(id);
                        $('#updateModal').modal()
                    })
                    var zdytable = new window.zdytable();
                    window.upload("{:U('import')}")

                    $("#addcity,#updatecity,#findcity").click(function (e) {
                        SelCity(this, e);
                    });
                })
            </script>

    </body>
</block>

</html>